gtk_widget_set_window (widget, gdk_window);
gtk_widget_register_window (widget, gdk_window);
- gtk_style_context_set_background (gtk_widget_get_style_context (widget), gdk_window);
+ /* We don't need to set a background on the GdkWindow; with decorations
+ * we draw the background ourself
+ */
+ if (!priv->client_decorated)
+ gtk_style_context_set_background (gtk_widget_get_style_context (widget), gdk_window);
return;
}
gtk_widget_register_window (widget, gdk_window);
- context = gtk_widget_get_style_context (widget);
- gtk_style_context_set_background (context, gdk_window);
-
+ /* We don't need to set a background on the GdkWindow; with decorations
+ * we draw the background ourself
+ */
+ if (!priv->client_decorated)
+ {
+ context = gtk_widget_get_style_context (widget);
+ gtk_style_context_set_background (context, gdk_window);
+ }
if (priv->transient_parent &&
gtk_widget_get_realized (GTK_WIDGET (priv->transient_parent)))